<?php
class Backoffice_Model_FormNewContact extends Zend_Form
{
    /** @var Doctrine\ORM\EntityManager */
    protected $_em;
    
    public function __construct(Doctrine\ORM\EntityManager $em, $options = null)
    {
        parent::__construct($options);
        $this->_em = $em;
        
        $name = new Zend_Form_Element_Text('name');
        $name->setAttrib('size', 28)
             ->setLabel("Contact Name")
             ->setRequired(true)
             ->addErrorMessage("A contact name is required");
        $this->addElement($name);
        
        $email = new Zend_Form_Element_Text('email');
        $email->setLabel("Email Address");
        $this->addElement($email);
        
        /*$address1 = new Zend_Form_Element_Text('address1');
        $address1->setLabel('Address')
                 ->removeDecorator('htmlTag')
                 ->removeDecorator('Errors');
        $this->addElement($address1);
        
        $address2 = new Zend_Form_Element_Text('address2');
        $address2->removeDecorator("label")
                 ->removeDecorator("htmlTag")
                 ->removeDecorator("Errors");
        $this->addElement($address2);
        
        $address3 = new Zend_Form_Element_Text('address3');
        $address3->removeDecorator("label")
                 ->removeDecorator("htmlTag")
                 ->removeDecorator("Errors");
        $this->addElement($address3);
        
        $postalCode = new Zend_Form_Element_Text('postalCode');
        $postalCode->removeDecorator("label")
                   ->removeDecorator("htmlTag")
                   ->removeDecorator("Errors");
        $this->addElement($postalCode);
        
        $phoneNumber = new Zend_Form_Element_Text('phoneNumber');
        $phoneNumber->setLabel('Phone Number');
        $this->addElement($phoneNumber);
        
        $cellNumber = new Zend_Form_Element_Text('cellNumber');
        $cellNumber->setLabel('Cell Number');
        $this->addElement($cellNumber);
        
        $faxNumber = new Zend_Form_Element_Text('faxNumber');
        $faxNumber->setLabel('Fax Number');
        $this->addElement($faxNumber);*/
    }
}